﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Diagnostics;
using System.Windows.Forms;

namespace ChallengePuzzle
{
    public class TimeChecker
    {
        static Stopwatch stopwatch = new Stopwatch();

        static public void Start()
        {
            stopwatch.Reset();
            stopwatch.Start();
        }
        static public string Stop()
        {
            stopwatch.Stop();
            return stopwatch.ElapsedTicks.ToString();
        }

        static public long StopTicks()
        {
            stopwatch.Stop();
            return stopwatch.ElapsedTicks;
        }

        static public long StopMilliseconds()
        {
            stopwatch.Stop();
            return stopwatch.ElapsedMilliseconds;
        }

        static public void StopAndShow()
        {
            stopwatch.Stop();
            MessageBox.Show(stopwatch.ElapsedMilliseconds.ToString());
        }

    }
}
